<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <link rel="stylesheet" href="./css/style.css">
    <link rel="stylesheet" href="https://unpkg.com/swiper/css/swiper.min.css">
    <script src="https://unpkg.com/swiper/js/swiper.min.js"></script>
    <style>
        .carsoual{
            width: 1380px;
            margin: 0 auto;
        }
        .swiper-container {
            width: 100%;
            height: 300px;
        }
        .swiper-pagination-bullet{
            background-color: red;
        }
    </style>
</head>
<body>
    <!-- 顶部部分 -->
    <div class="top">

    </div>
    <!-- 轮播部分 -->
    <div class="carsoual">
        <!-- Slider main container -->
        <div class="swiper-container">
            <!-- Additional required wrapper -->
            <div class="swiper-wrapper">
                <!-- Slides -->
                <div class="swiper-slide">
                    <img src="./img/1.jpg" alt="">
                </div>
                <div class="swiper-slide">
                    <img src="./img/2.jpg" alt="">
                </div>
                <div class="swiper-slide">
                    <img src="./img/3.jpg" alt="">
                </div>
                
            </div>
            <!-- If we need pagination -->
            <div class="swiper-pagination"></div>
        
            <!-- If we need navigation buttons -->
            <div class="swiper-button-prev"></div>
            <div class="swiper-button-next"></div>
        
            <!-- If we need scrollbar -->
            <!-- <div class="swiper-scrollbar"></div> -->
        </div>
        
    </div>
    <!-- 尾部部分 -->
    <div class="footer">

    </div>
    <script>
            var mySwiper = new Swiper ('.swiper-container', {
                // Optional parameters
                direction: 'horizontal',
                loop: true,

                // If we need pagination
                pagination: {
                    el: '.swiper-pagination',
                    clickable: true
                },

                // Navigation arrows
                navigation: {
                    nextEl: '.swiper-button-next',
                    prevEl: '.swiper-button-prev',
                },
                autoplay: {
                    delay: 3000,
                },

                // And if we need scrollbar
                // scrollbar: {
                //     el: '.swiper-scrollbar',
                // },
            })
    </script>

</body>
</html>